#include <stdio.h>
#include <stdlib.h>
#include <sys/types.h>
#include <unistd.h>
#include <signal.h>


int main(int argc, char* argv[])
{
    int pid = atoi(argv[1]);
    int sig = atoi(argv[2]);
    union sigval sv = {1234567};
    
    printf("current pid(%d) ...\n", getpid());
    printf("send sig(%d) to process(%d)...\n", sig, pid);
    
    sigqueue(pid, sig, sv);
    
    raise(SIGINT);
    
    while( 1 ) {
        printf("while...\n");
        sleep(1);
    }
    
    return 0;
}
